<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
 <head>
  <meta http-equiv="content-type" content="text/html; charset=UTF-8">
  <title>The Yaf_Request_Http class</title>
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-base.css" />
<link media="all" rel="stylesheet" type="text/css" href="styles/03e73060321a0a848018724a6c83de7f-theme-medium.css" />

 </head>
 <body class="docs"><div class="navbar navbar-fixed-top">
  <div class="navbar-inner clearfix">
    <ul class="nav" style="width: 100%">
      <li style="float: left;"><a href="yaf-request-abstract.setrouted.html">« Yaf_Request_Abstract::setRouted</a></li>
      <li style="float: right;"><a href="yaf-request-http.construct.html">Yaf_Request_Http::__construct »</a></li>
    </ul>
  </div>
</div>
<div id="breadcrumbs" class="clearfix">
  <ul class="breadcrumbs-container">
    <li><a href="index.html">PHP Manual</a></li>
    <li><a href="book.yaf.html">Yaf</a></li>
    <li>The Yaf_Request_Http class</li>
  </ul>
</div>
<div id="layout">
  <div id="layout-content"><div id="class.yaf-request-http" class="reference">

 <h1 class="title">The Yaf_Request_Http class</h1>
 

 <div class="partintro"><p class="verinfo">(Yaf &gt;=1.0.0)</p>


  <div class="section" id="yaf-request-http.intro">
   <h2 class="title">简介</h2>
   <p class="para">

   </p>
  </div>


  <div class="section" id="yaf-request-http.synopsis">
   <h2 class="title">类摘要</h2>


   <div class="classsynopsis">
    <div class="ooclass"></div>


    <div class="classsynopsisinfo">
     <span class="ooclass">
      <span class="modifier">class</span> <strong class="classname">Yaf_Request_Http</strong>
     </span>
     
     <span class="ooclass">
      <span class="modifier">extends</span>
       <a href="class.yaf-request-abstract.html" class="classname">Yaf_Request_Abstract</a>
     </span>
     {</div>

    <div class="classsynopsisinfo classsynopsisinfo_comment">/* 属性 */</div>

    
    <div class="classsynopsisinfo classsynopsisinfo_comment">/* 方法 */</div>
    <div class="methodsynopsis dc-description">
   <span class="methodname"><a href="yaf-request-http.construct.html" class="methodname">__construct</a></span>()</div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.get.html" class="methodname">get</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><a href="language.types.declarations.html#language.types.declarations.mixed" class="type mixed">mixed</a></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getcookie.html" class="methodname">getCookie</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><a href="language.types.declarations.html#language.types.declarations.mixed" class="type mixed">mixed</a></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getfiles.html" class="methodname">getFiles</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getpost.html" class="methodname">getPost</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><a href="language.types.declarations.html#language.types.declarations.mixed" class="type mixed">mixed</a></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getquery.html" class="methodname">getQuery</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><a href="language.types.declarations.html#language.types.declarations.mixed" class="type mixed">mixed</a></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getraw.html" class="methodname">getRaw</a></span>(): <span class="type"><a href="language.types.declarations.html#language.types.declarations.mixed" class="type mixed">mixed</a></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.getrequest.html" class="methodname">getRequest</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-http.isxmlhttprequest.html" class="methodname">isXmlHttpRequest</a></span>(): <span class="type">bool</span></div>

    
    <div class="classsynopsisinfo classsynopsisinfo_comment">/* 继承的方法 */</div>
    <div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.clearparams.html" class="methodname">Yaf_Request_Abstract::clearParams</a></span>(): <span class="type">bool</span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getactionname.html" class="methodname">Yaf_Request_Abstract::getActionName</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getbaseuri.html" class="methodname">Yaf_Request_Abstract::getBaseUri</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getcontrollername.html" class="methodname">Yaf_Request_Abstract::getControllerName</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getenv.html" class="methodname">Yaf_Request_Abstract::getEnv</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getexception.html" class="methodname">Yaf_Request_Abstract::getException</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getlanguage.html" class="methodname">Yaf_Request_Abstract::getLanguage</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getmethod.html" class="methodname">Yaf_Request_Abstract::getMethod</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getmodulename.html" class="methodname">Yaf_Request_Abstract::getModuleName</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getparam.html" class="methodname">Yaf_Request_Abstract::getParam</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getparams.html" class="methodname">Yaf_Request_Abstract::getParams</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getrequesturi.html" class="methodname">Yaf_Request_Abstract::getRequestUri</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.getserver.html" class="methodname">Yaf_Request_Abstract::getServer</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$default</code><span class="initializer"> = ?</span></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.iscli.html" class="methodname">Yaf_Request_Abstract::isCli</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isdispatched.html" class="methodname">Yaf_Request_Abstract::isDispatched</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isget.html" class="methodname">Yaf_Request_Abstract::isGet</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.ishead.html" class="methodname">Yaf_Request_Abstract::isHead</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isoptions.html" class="methodname">Yaf_Request_Abstract::isOptions</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.ispost.html" class="methodname">Yaf_Request_Abstract::isPost</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isput.html" class="methodname">Yaf_Request_Abstract::isPut</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isrouted.html" class="methodname">Yaf_Request_Abstract::isRouted</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.isxmlhttprequest.html" class="methodname">Yaf_Request_Abstract::isXmlHttpRequest</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setactionname.html" class="methodname">Yaf_Request_Abstract::setActionName</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$action</code></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setbaseuri.html" class="methodname">Yaf_Request_Abstract::setBaseUri</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$uir</code></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setcontrollername.html" class="methodname">Yaf_Request_Abstract::setControllerName</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$controller</code></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setdispatched.html" class="methodname">Yaf_Request_Abstract::setDispatched</a></span>(): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setmodulename.html" class="methodname">Yaf_Request_Abstract::setModuleName</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$module</code></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setparam.html" class="methodname">Yaf_Request_Abstract::setParam</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$name</code></span>, <span class="methodparam"><span class="type">string</span> <code class="parameter">$value</code><span class="initializer"> = ?</span></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setrequesturi.html" class="methodname">Yaf_Request_Abstract::setRequestUri</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$uir</code></span>): <span class="type"><span class="type void">void</span></span></div>
<div class="methodsynopsis dc-description"><span class="modifier">public</span> <span class="methodname"><a href="yaf-request-abstract.setrouted.html" class="methodname">Yaf_Request_Abstract::setRouted</a></span>(<span class="methodparam"><span class="type">string</span> <code class="parameter">$flag</code><span class="initializer"> = ?</span></span>): <span class="type"><span class="type void">void</span></span></div>


   }</div>


  </div>

  

  <div class="section" id="yaf-request-http.props">
   <h2 class="title">属性</h2>
   <dl>
    
     <dt id="yaf-request-http.props.module"><var class="varname">module</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.controller"><var class="varname">controller</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.action"><var class="varname">action</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.method"><var class="varname">method</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.params"><var class="varname">params</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.language"><var class="varname">language</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.exception"><var class="varname">_exception</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.base-uri"><var class="varname">_base_uri</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.uri"><var class="varname">uri</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.dispatched"><var class="varname">dispatched</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
    
     <dt id="yaf-request-http.props.routed"><var class="varname">routed</var></dt>

     <dd>

      <p class="para"/>
     </dd>

    
   </dl>

  </div>



 </div>

 
































































<h2>目录</h2><ul class="chunklist chunklist_reference"><li><a href="yaf-request-http.construct.html">Yaf_Request_Http::__construct</a> — The __construct purpose</li><li><a href="yaf-request-http.get.html">Yaf_Request_Http::get</a> — 从客户端返回变量</li><li><a href="yaf-request-http.getcookie.html">Yaf_Request_Http::getCookie</a> — 返回Cookie变量</li><li><a href="yaf-request-http.getfiles.html">Yaf_Request_Http::getFiles</a> — The getFiles purpose</li><li><a href="yaf-request-http.getpost.html">Yaf_Request_Http::getPost</a> — 返回POST变量</li><li><a href="yaf-request-http.getquery.html">Yaf_Request_Http::getQuery</a> — fetch a query parameter</li><li><a href="yaf-request-http.getraw.html">Yaf_Request_Http::getRaw</a> — Retrieve Raw request body</li><li><a href="yaf-request-http.getrequest.html">Yaf_Request_Http::getRequest</a> — The getRequest purpose</li><li><a href="yaf-request-http.isxmlhttprequest.html">Yaf_Request_Http::isXmlHttpRequest</a> — 是否为Ajax请求</li></ul>
</div>
</div></div></body></html>